feat(inbox): add Google Search Console as a self-driving source#3742
Merged
Conversation
Registers Google Search Console in the shared EXTERNAL_INBOX_SOURCES registry so the toggle card, source filter, and source-product unions pick it up. Adds a search_opportunity record kind (append-only incremental sync, like tickets) and a magnifying-glass icon. The generic DynamicSourceSetup already handles the source's OAuth grant and property picker, so no bespoke setup form is needed. Depends on the posthog/posthog backend PR shipping the google_search_console SignalSourceProduct choice first (the toggle create call rejects an unknown source_product with a 400).
|
😎 Merged successfully - details. |
|
React Doctor found no issues in the changed files. 🎉 Reviewed by React Doctor for commit |
Contributor
|
👋 Visual changes detected for this PR. Review and approve in PostHog Visual Review If these changes are unexpected, they may be caused by a flaky test or a broken snapshot on master. Don't approve — rerun the job or wait for a fix. |
There was a problem hiding this comment.
Purely additive registry entries (new inbox source + icon metadata) with no host-boundary or business-logic risk; author has strong familiarity with these exact files.
- Author wrote 100% of the modified lines and has 4 merged PRs in these paths (familiarity STRONG).
Gate mechanics and policy version
| Gate | Result | |
|---|---|---|
| prerequisites | ✓ | all clear |
| deny-list | ✓ | no deny categories matched |
| size | ✓ | 28L, 2F substantive — within ceiling |
| tier | ✓ | T1-agent / T1b-small (28L, 2F, single-area, feat) |
| stamphog 2.0.0b3 | .stamphog/policy.yml @ f057f43 · reviewed head 9b63f71 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Google Search Console is now a Self-driving inbox signal source (backend PR: PostHog/posthog#73079), but the inbox Sources modal had no way to turn it on or connect it.
Changes
Registers Google Search Console in the inbox source registry so it appears as a toggle and connects through the existing generic setup form.
EXTERNAL_INBOX_SOURCES: newgoogle_search_consoleentry (watchessearch_analytics_by_query_page,setup: "dynamic"). The toggle card, source filter, andSourceProductunions all derive from this registry, so no other wiring is needed.search_opportunityrecord kind.sourceNeedsFullRefreshtreats it as append-only (incremental sync) like tickets, because GSC's per-day search rows are immutable once written — unlike issues, which mutate and need full refresh.No bespoke setup form:
DynamicSourceSetupalready renders the source's OAuth grant (oauthfield, connect-by-kind) and property picker (oauth-account-select), which is exactly GSC's connect-form shape.Depends on PostHog/posthog#73079 shipping first. The toggle's create call sends
source_product: "google_search_console", which the Signals model rejects with a 400 until that backend PR lands the enum value.How did you test this?
pnpm --filter @posthog/shared build,biome linton the changed files, andpnpm typecheckacross the repo (24/24 packages) all pass. The unions consumed across packages type-check against the new registry entry.typecheck), and there is no runtime registry test to extend.Automatic notifications